<!DOCTYPE html>

<html lang="en">
<head>
    <link rel="shortcut icon" href="{{ static_url('img/scenery-24.ico') }}" type="image/x-icon" />
    <meta charset="utf-8">
    <title>django-blog</title>
    <meta name="description" content="">
    <meta name="author" content="tinywell">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    
    <!-- 新 Bootstrap 核心 CSS 文件 -->
    <link rel="stylesheet" href="//cdn.bootcss.com/bootstrap/3.3.5/css/bootstrap.min.css"> 
    
    <style type="text/css">
        body {
            padding-top: 60px;
        }
    </style>
    <!--[if lt IE 9]>
    <script src="//html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    
    <!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
    <script src="//cdn.bootcss.com/jquery/1.11.3/jquery.min.js"></script>
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <script src="//cdn.bootcss.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
    
    {% block extra_head %}{% end %}
    
</head>
<body>

<nav class="navbar navbar-default  navbar-fixed-top">
  <div class="container-fluid">
    <div class="navbar-header">
      <a class="navbar-brand" href="/">
          <img alt="Brand" class="pull-left" style="position:relative;top:-6px;"  
                src="{{ static_url('img/scenery-32.ico') }}">
          <span style="margin:auto 10px">Tornado-Blog</span>
      </a>
      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" 
            data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
    </div>
    <!-- Collect the nav links, forms, and other content for toggling -->
    <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
      <ul class="nav navbar-nav">
        <li><a href="/admin" class="">Admin</a></li>
        <li class="active"><a href="/blog">Blog</a></li>
        <li><a href="/edit">New</a></li>
      </ul>
      <ul class="nav navbar-nav navbar-right">
        {% if current_user %}
        <li>
            <img style="" class="img-circle" src="{{ static_url('img/scenery-48.ico') }}" />
        </li>
        <li class="dropdown">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" 
                    aria-haspopup="true" aria-expanded="false">
                {{ current_user }}
                <span class="caret"></span>
            </a>
            <ul class="dropdown-menu">
                <li><a href="" class=""> {{ current_user }} </a></li>
                <li><a href="/blog"> {{ _("我的博客") }} </a></li>
                <li role="separator" class="divider"></li>
                <li><a href="/logout">{{ _("注销") }}</a></li>
            </ul>
         </li>
        {% else %}
        <li><a class="" href="/login">
            <span class="glyphicon glyphicon-plus-sign" aria-hidden="true"></span>{{ _("登录") }} </a></li>
        {% end %}
      </ul>
    </div><!-- /.navbar-collapse -->
    <div class="">
        
    </div>
  </div><!-- /.container-fluid -->
</nav>

<div class="container">
    
    {% block content %}Empty page{% end %}
    <p><hr></p>
    <footer class="row">
        <div class="col-xs-6">
            <p>This is <a href="https://coding.net/u/tinywell/p/tornado_test/git">tornado-blog-test</a></p>
        </div>
        <div class="col-xs-6" style="text-align:right">
            <p>
                &copy; <a href="https://coding.net/tinywell">tinywell</a> 2016
                |
                <a href="#">license</a>
            </p>
        </div>
    </footer>
</div> <!-- container -->

{% block extra_footer %}{% end %}

</body>
</html>
